﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace QLTSCD
{
    public partial class Form1 : DevComponents.DotNetBar.Office2007RibbonForm
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void btnNCC_Click(object sender, EventArgs e)
        {

            FormCollection FC = Application.OpenForms;
            bool flag = false;
            foreach (Form f in FC)
            {
                if (f.Name == "frmNCC")
                {
                    f.BringToFront();
                    flag = true;
                    break;
                }

            }

            if (!flag)
            {
                frmNCC frm = new frmNCC();
                frm.MdiParent = this;
                frm.Show();


            }

        }

        private void buttonItem15_Click(object sender, EventArgs e)
        {
            FormCollection FC = Application.OpenForms;
            bool flag = false;
            foreach (Form f in FC)
            {
                if (f.Name == "frmPB")
                {
                    f.BringToFront();
                    flag = true;
                    break;
                }

            }

            if (!flag)
            {
                frmPB frm = new frmPB();
                frm.MdiParent = this;
                frm.Show();
            }
        }

        private void Form1_Load(object sender, EventArgs e)
        {
            
        }

        private void btnPhieuNhap_Click(object sender, EventArgs e)
        {
            FormCollection FC = Application.OpenForms;
            bool flag = false;
            foreach (Form f in FC)
            {
                if (f.Name == "frmPhieuNhap")
                {
                    f.BringToFront();
                    flag = true;
                    break;
                }

            }

            if (!flag)
            {
                frmPhieuNhap frm = new frmPhieuNhap();
                frm.MdiParent = this;
                frm.Show();
            }
        }

     
    
    }
}
